/*
 * @Author: 啊彪
 * @Date: 2021-08-26 11:09:54
 * @LastEditors: 啊彪
 * @LastEditTime: 2021-08-26 11:16:07
 * @Description: 武将碎片
 * @FilePath: \fkxzg\src\model\hero\heroFrag.model.ts
 */

import mongoose from 'mongoose';

const Schema = mongoose.Schema;
const HeroFragSchema: mongoose.Schema = new Schema({
    roleId: { type: Number, desc: '角色Id', index: true },
    id: { type: Number, desc: '武将Id', index: true },
    name: { type: String, desc: '武将名称' },
    num: { type: Number, desc: '数量' }
}, { versionKey: false }).index({ roleId: 1, id: 1 });

const HeroFrag = mongoose.model('HeroFrag', HeroFragSchema);
export default HeroFrag;
